/*
 * 版权所有 (C) 2015 知启蒙(ZHIQIM) 保留所有权利。
 * 
 * 欢迎到知启蒙网站（https://www.zhiqim.com）购买正版软件，知启蒙还提供许多开源框架和软件。
 * 
 * 1、本软件产品所有源代码受《中华人民共和国著作权法》和其他有关法律、法规的保护，其所有知识产权归湖南知启蒙科技有限公司所有；
 * 2、禁止复制和修改。不得复制修改、翻译或改编本软件所有源代码，或者基于本软件产品创作衍生作品；
 * 3、禁止进行逆向工程。不得对本软件的源代码进行逆向工程、反编译或试图以其他方式发现软件的源代码；
 * 4、个别授权：如需进行商业性的销售、复制、分发，包括但不限于软件销售、预装、捆绑等，必须获得知启蒙的书面授权和许可；
 * 5、保留权利：本注释未明示授权的其他一切权利仍归知启蒙所有，任何人使用其他权利时必须获得知启蒙的书面同意。
*/
package net.redxyz.open.api.dbo;

import java.io.Serializable;

import org.zhiqim.kernel.annotation.AnAlias;
import org.zhiqim.kernel.annotation.AnNew;
import org.zhiqim.kernel.json.Jsons;
import org.zhiqim.orm.annotation.*;

/**
 * APP 订单表 对应表《APP_TRADE》
 */
@AnAlias("AppTrade")
@AnNew
@AnTable(table="APP_TRADE", key="APP_KEY,SELLER_NICK,TID", type="InnoDB")
@AnIndex({@AnIndexValue(name="IX_CREATED", column="CREATED", unique=false),
          @AnIndexValue(name="IX_TRADE_CREATE_TIME", column="TRADE_CREATE_TIME", unique=false),
          @AnIndexValue(name="IX_TRADE_YEAR", column="TRADE_YEAR", unique=false),
          @AnIndexValue(name="IX_TRADE_MONTH", column="TRADE_MONTH", unique=false),
          @AnIndexValue(name="IX_TRADE_DAY_DATE", column="TRADE_DAY_DATE", unique=false)})
public class AppTrade implements Serializable
{
    private static final long serialVersionUID = 1L;

    @AnTableField(column="APP_KEY", type="long", notNull=true)    private long appKey;    //1.应用ID
    @AnTableField(column="SELLER_NICK", type="string,100", notNull=true)    private String sellerNick;    //2.卖家昵称
    @AnTableField(column="TID", type="string,32", notNull=true)    private String tid;    //3.订单号
    @AnTableField(column="STATUS", type="string,64", notNull=true)    private String status;    //4.订单状态
    @AnTableField(column="MODIFIED", type="string,20", notNull=true)    private String modified;    //5.修改时间
    @AnTableField(column="OAID", type="string,130", notNull=true)    private String oaid;    //6.首件人地址信息
    @AnTableField(column="CREATED", type="string,20", notNull=true)    private String created;    //7.创建时间
    @AnTableField(column="RECEIVER_NAME", type="string,100", notNull=true)    private String receiverName;    //8.收件人信息
    @AnTableField(column="RECEIVER_MOBILE", type="string,32", notNull=false)    private String receiverMobile;    //9.收件人手机号
    @AnTableField(column="RECEIVER_PHONE", type="string,32", notNull=false)    private String receiverPhone;    //10.收件人手机号
    @AnTableField(column="RECEIVER_ADDRESS", type="string,300", notNull=true)    private String receiverAddress;    //11.详细地址
    @AnTableField(column="RECEIVER_STATE", type="string,32", notNull=true)    private String receiverState;    //12.省份
    @AnTableField(column="RECEIVER_CITY", type="string,32", notNull=true)    private String receiverCity;    //13.城市
    @AnTableField(column="RECEIVER_DISTRICT", type="string,32", notNull=false)    private String receiverDistrict;    //14.区县
    @AnTableField(column="BUYER_NICK", type="string,100", notNull=true)    private String buyerNick;    //15.卖家昵称
    @AnTableField(column="PAY_TIME", type="string,20", notNull=false)    private String payTime;    //16.付款时间
    @AnTableField(column="PAYMENT", type="string,20", notNull=false)    private String payment;    //17.付款金额
    @AnTableField(column="TOTAL_FEE", type="string,20", notNull=false)    private String totalFee;    //18.订单总价
    @AnTableField(column="TRADE_YEAR", type="int", notNull=true)    private int tradeYear;    //19.入库年份，yyyy
    @AnTableField(column="TRADE_MONTH", type="int", notNull=true)    private int tradeMonth;    //20.入库时，月份MM
    @AnTableField(column="TRADE_DAY_DATE", type="int", notNull=true)    private int tradeDayDate;    //21.入库时，月份yyyyMMdd
    @AnTableField(column="TRADE_CREATE_TIME", type="string,20", notNull=true)    private String tradeCreateTime;    //22.入库时间
    @AnTableField(column="TRADE_JSON", type="string,20000", notNull=false)    private String tradeJson;    //23.订单JSON 数据，包括子订单信息

    public String toString()
    {
        return Jsons.toString(this);
    }

    public long getAppKey()
    {
        return appKey;
    }

    public void setAppKey(long appKey)
    {
        this.appKey = appKey;
    }

    public String getSellerNick()
    {
        return sellerNick;
    }

    public void setSellerNick(String sellerNick)
    {
        this.sellerNick = sellerNick;
    }

    public String getTid()
    {
        return tid;
    }

    public void setTid(String tid)
    {
        this.tid = tid;
    }

    public String getStatus()
    {
        return status;
    }

    public void setStatus(String status)
    {
        this.status = status;
    }

    public String getModified()
    {
        return modified;
    }

    public void setModified(String modified)
    {
        this.modified = modified;
    }

    public String getOaid()
    {
        return oaid;
    }

    public void setOaid(String oaid)
    {
        this.oaid = oaid;
    }

    public String getCreated()
    {
        return created;
    }

    public void setCreated(String created)
    {
        this.created = created;
    }

    public String getReceiverName()
    {
        return receiverName;
    }

    public void setReceiverName(String receiverName)
    {
        this.receiverName = receiverName;
    }

    public String getReceiverMobile()
    {
        return receiverMobile;
    }

    public void setReceiverMobile(String receiverMobile)
    {
        this.receiverMobile = receiverMobile;
    }

    public String getReceiverPhone()
    {
        return receiverPhone;
    }

    public void setReceiverPhone(String receiverPhone)
    {
        this.receiverPhone = receiverPhone;
    }

    public String getReceiverAddress()
    {
        return receiverAddress;
    }

    public void setReceiverAddress(String receiverAddress)
    {
        this.receiverAddress = receiverAddress;
    }

    public String getReceiverState()
    {
        return receiverState;
    }

    public void setReceiverState(String receiverState)
    {
        this.receiverState = receiverState;
    }

    public String getReceiverCity()
    {
        return receiverCity;
    }

    public void setReceiverCity(String receiverCity)
    {
        this.receiverCity = receiverCity;
    }

    public String getReceiverDistrict()
    {
        return receiverDistrict;
    }

    public void setReceiverDistrict(String receiverDistrict)
    {
        this.receiverDistrict = receiverDistrict;
    }

    public String getBuyerNick()
    {
        return buyerNick;
    }

    public void setBuyerNick(String buyerNick)
    {
        this.buyerNick = buyerNick;
    }

    public String getPayTime()
    {
        return payTime;
    }

    public void setPayTime(String payTime)
    {
        this.payTime = payTime;
    }

    public String getPayment()
    {
        return payment;
    }

    public void setPayment(String payment)
    {
        this.payment = payment;
    }

    public String getTotalFee()
    {
        return totalFee;
    }

    public void setTotalFee(String totalFee)
    {
        this.totalFee = totalFee;
    }

    public int getTradeYear()
    {
        return tradeYear;
    }

    public void setTradeYear(int tradeYear)
    {
        this.tradeYear = tradeYear;
    }

    public int getTradeMonth()
    {
        return tradeMonth;
    }

    public void setTradeMonth(int tradeMonth)
    {
        this.tradeMonth = tradeMonth;
    }

    public int getTradeDayDate()
    {
        return tradeDayDate;
    }

    public void setTradeDayDate(int tradeDayDate)
    {
        this.tradeDayDate = tradeDayDate;
    }

    public String getTradeCreateTime()
    {
        return tradeCreateTime;
    }

    public void setTradeCreateTime(String tradeCreateTime)
    {
        this.tradeCreateTime = tradeCreateTime;
    }

    public String getTradeJson()
    {
        return tradeJson;
    }

    public void setTradeJson(String tradeJson)
    {
        this.tradeJson = tradeJson;
    }

}
